﻿


var gdViewModel;



$(function () {

    //$('body').scrollspy({ target: '.navbar' })
    //$('#navbar').scrollspy();
    $('body').scrollspy({ target: '.navbar' })

    function gridViewModel() {
        var self = this;


        //初始化
        self.init = function () {

            
        }
        self.initEd = function () {//结束初始化
        }




       



        



       
        //TO Add Method




        //点击“返回试题列表”按钮，返回到试卷列表
        self.BackToPaperList = function () {
         
                window.location.href = "/TeacherManger/TestLibExamView?CourseID=" + $("#HiddenCourseID").val();
           

        }


            //转换题型为对应的字符串
            self.formatIProblemType = function (value) {
                switch (value) {
                    case 1:
                        return "单项选择题"
                        break;
                    case 2:
                        return "多项选择题"
                        break;
                    case 3:
                        return "判断题"
                        break;
                    default:
                        break;
                }
            }








        }


    var gdViewModel = new gridViewModel();
    



        gdViewModel.init();
        ko.applyBindings(gdViewModel);





});



